package com.pdemo.core.entity;

import java.util.Date;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import com.pdemo.core.genericdao.IEntity;

@Entity
@Table(name="User_Activity")
public class UserActivity implements IEntity<Long>{
	private static final long serialVersionUID = 798797801128345249L;

	

	@Id
	@Column(name="id")
	@GeneratedValue(generator="sequence")
	@SequenceGenerator(name="sequence",sequenceName="ID_SEQ")
	private Long id;
	
	@ManyToOne(cascade=CascadeType.ALL)
	private User user;
	
	@Column(name="ACTION",length=30)
	private Activity action;
	
	@Column(name="ACTION_AT")
	@Temporal(TemporalType.TIMESTAMP)
	private Date actionTime;
	
	@Column(name="PLATFORM",length=15)
	private String platform;
	
	@Column(name="MOBILE_MODEL",length=30)
	private String mobileModel;
	
	@Column(name="UUID", length=25)
	private String uuid;
	
	@Column(name="IP_ADDRESS",length=25)
	private String ipAddress;
	
	@Column(name="GPS",length=50)
	private String gps;

	@Override
	public Long getId() {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public void setId(Long id) {
		// TODO Auto-generated method stub
		
	}

}
